# 定义类
class Student:
    name: ''
    age: 0
    sex: ''

    def __init__(self, name, age, sex):
        self.name = name
        self.age = age
        self.sex = sex

# Student.name = '张三'
# print(Student.__dict__)


# 创建对象
stu1 = Student('李四', 18, '男')
# stu1.name = '李四'
# stu1.sex = '男'
# stu1.age = 18
print(stu1)
print(stu1.__dict__)

stu2 = Student("王二小", 20, "女")
print(stu2.__dict__)

stu3 = Student()


